#include<iostream>
#include<cstdio>
#define N 601
#define M 200000
using namespace std;
const int inf=(int)(1e9);
const long long INF=(long long)(1e18);
int read()
{
	char c=0;
	int sum=0;
	while (c<'0'||c>'9') c=getchar();
	while ('0'<=c&&c<='9') sum=sum*10+c-'0',c=getchar();
	return sum;
}
int n,m,q,len=1,s,t,head[N+1],dis[N+1],pvt[N+1],length;
long long delta[N+1],tong[N+1],ans=INF;
bool used[N+1];
struct node
{
	int v,data,cost,nxt;
};
node edge[M+1];
void add(int x,int y,int z,int w)
{
	edge[++len]=(node){y,z,w,head[x]},head[x]=len;
	edge[++len]=(node){x,0,-w,head[y]},head[y]=len;
	return;
}
void dijkstra()
{
	int x,top,minn;
	for (int i=s;i<=t;++i) dis[i]=inf,used[i]=0;
	dis[s]=0;
	for (int i=1;i<=(n<<1)+1;++i)
	{
		top=0,minn=inf;
		for (int j=s;j<=t;++j)
			if (!used[j]&&dis[j]<minn)
				top=j,minn=dis[j];
		used[top]=1;
		for (int j=head[top];j>0;j=edge[j].nxt)
			if (edge[j].data&&dis[edge[j].v]>dis[top]+delta[top]-delta[edge[j].v]+edge[j].cost)
				pvt[edge[j].v]=j,dis[edge[j].v]=dis[top]+delta[top]-delta[edge[j].v]+edge[j].cost;
	}
	if (dis[t]!=inf)
	{
		x=t;
		while (x!=s) edge[pvt[x]].data--,edge[pvt[x]^1].data++,x=edge[pvt[x]^1].v;
		for (int i=s;i<=t;++i) delta[i]+=dis[i];
	}
	return;
}
int main()
{
	freopen("journey.in","r",stdin);
	freopen("journey.out","w",stdout);
	int x,y,z;
	n=read(),m=read(),q=read(),s=0,t=(n<<1)+1;
	for (int i=1;i<=n;++i) add(s,i,1,0),add(i+n,i,inf,0),add(i+n,t,1,0);
	for (int i=1;i<=m;++i) x=read(),y=read(),z=read(),add(x,y+n,inf,z);
	for (int i=1;i<=n;++i)
	{
		dijkstra();
		if (dis[t]!=inf) ++length,tong[length]=tong[length-1]+delta[t];
		else break;
	}
	while (q--)
	{
		x=read(),ans=INF;
		for (int i=0;i<=length;++i) ans=min(ans,tong[i]+1ll*(n-i)*x);
		printf("%lld\n",ans);
	}
	return 0;
}
